//
//  PishangCell.m
//  中皮网
//
//  Created by ios程序员 on 15/10/31.
//  Copyright (c) 2015年 ios程序员. All rights reserved.
//

#import "PishangCell.h"

@implementation PishangCell

-(instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        self.firstImage = [[UIImageView alloc] init];
        [self.contentView addSubview:self.firstImage];
        [self.firstImage setImage:[UIImage imageNamed:@"dd"]];
//        self.firstImage.backgroundColor = [UIColor redColor];
        
        
        self.firstLabel = [[UILabel alloc] init];
        [self.contentView addSubview:self.firstLabel];
//        self.firstLabel.backgroundColor = [UIColor greenColor];
        self.firstLabel.text = @"发达的大额KC皮草";
        self.firstLabel.font = [UIFont systemFontOfSize:11];
        
        self.upLabel = [[UILabel alloc ] init];
        [self.contentView addSubview:self.upLabel];
        self.upLabel.textColor = [UIColor redColor];
        self.upLabel.text = @"198.00";
        self.upLabel.font = [UIFont systemFontOfSize:11];
//        self.upLabel.backgroundColor = [UIColor blackColor];
        
        self.dowenLabel = [[UILabel alloc] init];
        self.dowenLabel.text = @"哈尔滨";
        self.dowenLabel.font = [UIFont systemFontOfSize:11];

        [self.contentView addSubview:self.dowenLabel];
        self.rightLabel = [[UILabel alloc ] init];
        self.rightLabel.text = @"包邮";
        self.rightLabel.font = [UIFont systemFontOfSize:11];

        
        
//        self.dowenLabel.backgroundColor = [UIColor blueColor];
//        self.rightLabel.backgroundColor = [UIColor yellowColor];
        [self.contentView addSubview:self.rightLabel];
        
    }
    return self;
}

-(void)layoutSubviews{
    
    self.firstImage.frame = CGRectMake(0, 0,100 , 100);
    self.firstLabel.frame = CGRectMake(120, 0, 200, 20);
    self.upLabel.frame = CGRectMake(120, 30, 100, 10);
    self.dowenLabel.frame = CGRectMake(120, 80, 50, 10);
    self.rightLabel.frame = CGRectMake(200, 80, 50, 10);
    
}


/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

@end
